package assignment4.part1;

public class SymmetricCrypt {
	public static final String password = "hs82_d82-990028-d2yuia:dfd";
	public static final String plaintext = "Some DUDE thought he had SWAGGER, but he didn't!";
	
	public static void main(String args[]) throws Exception {
		System.out.println("Encrypting to out.txt: " + plaintext);
		Encrypt.EncryptToFile(SymmetricCrypt.plaintext, SymmetricCrypt.password, "out.txt");
		System.out.println("Encryption done, decrypting from out.txt: " + Decrypt.DecryptFromFile(password, "out.txt"));
		System.out.println();
		
		System.out.println("Encrypting: " + plaintext);
		byte[] enc = Encrypt.EncryptString(plaintext, SymmetricCrypt.password);
		System.out.println("Encryption done, decrypting...");
		byte[] dec = Decrypt.DecryptString(enc, SymmetricCrypt.password);
		System.out.println("Decrypted to: " + new String(dec));
	}
}
